package com.hqyj.controller;



import com.hqyj.pojo.SupplierFoodList;
import com.hqyj.service.SupplierFoodListService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;


@RestController
@RequestMapping("/supplierFood")
public class SupplierFoodListController {
    @Autowired
    SupplierFoodListService supplierFoodListService;

    //加载表格数据
    @RequestMapping("/supplierFoodList")
    public  HashMap<String,Object> listPage(SupplierFoodList f){
        return  supplierFoodListService.select(f);
    }
    //修改
    @RequestMapping("/update")
    public HashMap<String,Object>  update(SupplierFoodList f){ return supplierFoodListService.update(f);
    }
    //新增
    @RequestMapping("/add")
    public HashMap<String,Object> add( SupplierFoodList f){
        return supplierFoodListService.add(f);
    }

    //删除
    @RequestMapping("/del")
    public HashMap<String,Object> del(Integer id){
        return supplierFoodListService.del(id);
    }

}
